<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition template="/template.xhtml"
                xmlns="http://www.w3.org/1999/xhtml"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:p="http://primefaces.org/ui"
                xmlns:f="http://java.sun.com/jsf/core" >
    <ui:define name="title">
        <h:outputText value="#{bundle.ViewStatusTitle}"></h:outputText>
    </ui:define>
    <ui:define name="body">
        <h:form id="form" styleClass="form" rendered="#{userController.allowedGroups('1,2')}">
            <p:fieldset legend="Status Information"  >
                 <div class="icon_left">
                        <h:commandLink  action="/status/List" styleClass="menu_item" >
                            <h:graphicImage  value="../resources/images/syscon/set.png"   />
                            <br/>
                            <h:outputText  value="Status"/>
                        </h:commandLink>
                    </div>
                <h:outputText value="#{statusController.current.stsStatus}" styleClass="engraved"/>
                <br/>
                <h:outputLabel value="Color:" styleClass="label" />
                <p:colorPicker id="popupCP" value="#{statusController.current.stsColor}"  widgetVar="picker"/>
                <p:spacer width="10"/>
                <h:outputLabel value="Color Description:"  styleClass="label" />
                <h:outputLabel id="stsStatus" value="#{statusController.current.stsStatus}" title="#{bundle.CreateStatusTitle_stsStatus}"/>
                <p:spacer width="10"/>
                 <p:separator/>
                <p:commandButton icon="ui-icon-plus" ajax="false" action="#{statusController.prepareCreate}" value="New" />
                <p:spacer width="10"/>
                <p:commandButton icon="ui-icon-pencil" ajax="false" action="#{statusController.prepareEdit}" value="Edit"/>
                <p:spacer width="10"/>
                <p:commandButton icon="ui-icon-close"   ajax="false"  action="#{statusController.destroyAndView}" value="Delete" />
                <p:spacer width="10"/>
                <p:commandButton icon="ui-icon-list" ajax="false" action="#{statusController.prepareList}" value="Show All"/>
                <br/>
                <br/>
            </p:fieldset>

        </h:form>
    </ui:define>
</ui:composition>


